import 'package:app/page/Engineering/engineering_query.dart';
import 'package:app/widget/tap_appbar.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
class EmergencyPage extends StatefulWidget {
  @override
  _EmergencyPageState createState() => _EmergencyPageState();
}

class _EmergencyPageState extends State<EmergencyPage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: TapAppBar(
          TapViewBar(
             Text("抢险工程"),
           ),
        Size.fromHeight(ScreenUtil().setHeight(80))
      ),
      body: Column(
        children: <Widget>[
          InkWell(
            onTap: (){
              Navigator.of(context).push( MaterialPageRoute(builder: (context)=>EngineeringQuery()));
            },
            child:getItem("images/home/f3.gif", "工程查询")
          ),
          InkWell(
              onTap: (){},
              child:getItem("images/home/f3.gif", "工程查询")
          ),
          InkWell(
              onTap: (){},
              child:getItem("images/home/f3.gif", "工程查询")
          ),
          InkWell(
              onTap: (){},
              child:getItem("images/home/f3.gif", "工程查询")
          ),
          InkWell(
              onTap: (){},
              child:getItem("images/home/f3.gif", "工程查询")
          ),

    //      getItem(icon, title),getItem(icon, title),getItem(icon, title),getItem(icon, title),


        ],
      ),
    );
  }
  Widget getItem(String icon,String title){
    return Container(
      alignment: Alignment.center,
      height: ScreenUtil().setHeight(120),
      margin: EdgeInsets.only(left: 50),
      decoration: BoxDecoration(
        border: Border(bottom:BorderSide(
          width: 1,color: Colors.black12
        ))
      ),
      child: ListTile(
      leading: Image.asset(icon),
      title: Text(title),
      trailing: IconButton(icon: Icon(Icons.arrow_forward_ios), onPressed: null),
      ),
    );
  }
}
